package staticfactory;

/**
 * @author gaopeng
 * @date 2019/12/7 6:24 下午
 */
public class NvWa {
    public static void main(String[] args) {
        Human white = HumanFactory.createHuman(WhiteHuman.class);
        white.getColor();
        white.getLanguage();
        Human black = HumanFactory.createHuman(BlackHuman.class);
        black.getColor();
        black.getLanguage();
        Human yellow = HumanFactory.createHuman(YellowHuman.class);
        yellow.getColor();
        yellow.getLanguage();
    }
}
